cmake_minimum_required(VERSION 3.20)
project(xlog)

#改变行为的变量 BUILD_SHARED_LIBS ON生成动态库，默认OFF生成静态库
set(BUILD_SHARED_LIBS ON)

#描述系统的变量
message("MSVC = " ${MSVC})
message("WIN32 = " ${WIN32})
message("UNIX = " ${UNIX})
message("CMAKE_SYSTEM_NAME = " ${CMAKE_SYSTEM_NAME})

#控制生成makefile的指令，不要带颜色
set(CMAKE_COLOR_MAKEFILE OFF)

#获取项目名称 ${PROJECT_NAME}这个项目对应xlog
add_library(${PROJECT_NAME} xlog.cpp xlog.h)

